<tagLib name="fanwe" />
<include file="Public:header" />
<script type="text/javascript" src="__TMPL__Static/Js/user.js"></script>
<div class="tabs-title">
	<fanwe:linkBtn text="{$Think.lang.RETURN_LIST}" href="{:U(MODULE_NAME.'/index')}" />
	<div class="tt-item active" rel="1"><p><a href="javascript:;">{$Think.lang.TAB_1}</a></p></div>
	<div class="tt-item" rel="2"><p><a href="javascript:;">{$Think.lang.TAB_2}</a></p></div>
	<!--<div class="tt-item" rel="3"><p><a href="javascript:;">{$Think.lang.TAB_3}</a></p></div>-->
	<div class="tt-item" rel="4"><p><a href="javascript:;">{$Think.lang.TAB_4}</a></p></div>
</div>
<form method='post' id="form" name="form" action="{:U(MODULE_NAME.'/update')}" enctype="multipart/form-data">
<div class="tabs-body">
	<table cellpadding="4" cellspacing="0" border="0" class="tabs-item tabs-active table-form" rel="1">
		<tr>
			<th width="200">{$Think.lang.USER_NAME}</th>
			<td><input type="text" class="textinput requireinput" name="user_name" id="user_name" value="{$vo.user_name}" /></td>
		</tr>
		<tr>
			<th>{$Think.lang.EMAIL}</th>
			<td><input type="text" class="textinput requireinput" name="email" id="email"  value="{$vo.email}" /></td>
		</tr>
		<tr>
			<th>{$Think.lang.PASSWORD}</th>
			<td>
				<input type="password" class="textinput" name="password" id="password" />
				&nbsp;<span>{$Think.lang.PASSWORD_TIPS}</span>
			</td>
		</tr>
		<tr>
			<th>{$Think.lang.GID}</th>
			<td>
				<select name="gid" id="user_group">
					<foreach name="group_list" key="gid" item="gname">
					<option value="{$gid}" <if condition="$gid eq $vo['gid']">selected="selected"</if>>{$gname}</option>
					</foreach>
				</select>
			</td>
		</tr>
		<tr>
			<th>{$Think.lang.AVATAR}</th>
			<td>
				<label><input type="checkbox" name="delete_avatar" value="1" /> <span>{$Think.lang.DELETE_AVATAR}</span></label>
			</td>
		</tr>
		<tr>
			<th>&nbsp;</th>
			<td>
				<input type="file" class="fileinput" name="avatar_img" size="30" />
			</td>
		</tr>
		<if condition="$vo['avatar'] gt 0">
		<tr>
			<th>&nbsp;</th>
			<td>
				<img src="<?php echo getImgById($vo['avatar'],0,0,0,1) ?>" height="32" style="border:solid 1px #ccc;" />
			</td>
		</tr>
		</if>
		<tr>
			<th>{$Think.lang.CREDITS}</th>
			<td><input type="text" class="textinput" name="credits" value="{$vo.credits}" /></td>
		</tr>
		<tr>
			<th>{$Think.lang.MONEY}</th>
			<td><input type="text" class="textinput" name="money" value="{$vo.money}" /></td>
		</tr>
		<tr>
			<th>{$Think.lang.REG_TIME}</th>
			<td><input type="text" class="textinput" name="reg_time" value="{:toDate($vo['reg_time'])}" /></td>
		</tr>
		<tr>
			<th>{$Think.lang.REG_IP}</th>
			<td><input type="text" class="textinput" name="us[reg_ip]" value="{$vo.reg_ip}" /></td>
		</tr>
	</table>
	<table cellpadding="4" cellspacing="0" border="0" class="table-form tabs-item" rel="2">
		<tr>
			<th width="200">{$Think.lang.GENDER}</th>
			<td>
				<label><input type="radio" name="up[gender]" value="0" <if condition="0 eq $vo['gender']">checked="checked"</if> /> <span>{$Think.lang.GENDER_0}</span></label>&nbsp;
				<label><input type="radio" name="up[gender]" value="1" <if condition="1 eq $vo['gender']">checked="checked"</if> /> <span>{$Think.lang.GENDER_1}</span></label>
			</td>
		</tr>
		<tr>
			<th>{$Think.lang.WEIBO}</th>
			<td><input type="text" class="textinput" name="up[weibo]" value="{$vo.weibo}" /></td>
		</tr>
		<tr>
			<th>{$Think.lang.RESIDE}</th>
			<td>
				<select name="up[reside_province]" id="province" onchange="getCitys('#province','#city');">
					<foreach name="province_list" key="province_id" item="province_name">
					<option value="{$province_id}" <if condition="$province_id eq $vo['reside_province']">selected="selected"</if>>{$province_name}</option>
					</foreach>
				</select>&nbsp;
				<select name="up[reside_city]" id="city">
					<foreach name="city_list" key="city_id" item="city_name">
					<option value="{$city_id}" <if condition="$city_id eq $vo['reside_city']">selected="selected"</if>>{$city_name}</option>
					</foreach>
				</select>
			</td>
		</tr>
		<tr>
			<th>{$Think.lang.INTRODUCE}</th>
			<td>
				<textarea name="up[introduce]" class="areainput" rows="5">{$vo.introduce}</textarea>
			</td>
		</tr>
	</table>
	<table cellpadding="4" cellspacing="0" border="0" class="table-form tabs-item" rel="3">
		<tr>
			<th width="200">{$Think.lang.LAST_TIME}</th>
			<td><p><span>{:toDate($vo['last_time'])}</span></p></td>
		</tr>
		<tr>
			<th>{$Think.lang.LAST_IP}</th>
			<td><p><span>{$vo.last_ip}</span></p></td>
		</tr>
		<tr>
			<th>{$Think.lang.SHARES}</th>
			<td><p>(<a href="#">{$vo.shares}</a>)</p></td>
		</tr>
		<tr>
			<th>{$Think.lang.PHOTOS}</th>
			<td><p>(<a href="#">{$vo.photos}</a>)</p></td>
		</tr>
		<tr>
			<th>{$Think.lang.GOODS}</th>
			<td><p>(<a href="#">{$vo.goods}</a>)</p></td>
		</tr>
		<tr>
			<th>{$Think.lang.FORUMS}</th>
			<td><p>(<a href="#">{$vo.forums}</a>)</p></td>
		</tr>
		<tr>
			<th>{$Think.lang.FORUM_POSTS}</th>
			<td><p>(<a href="#">{$vo.forum_posts}</a>)</p></td>
		</tr>
		<tr>
			<th>{$Think.lang.ASK}</th>
			<td><p>(<a href="#">{$vo.ask}</a>)</p></td>
		</tr>
		<tr>
			<th>{$Think.lang.ASK_POSTS}</th>
			<td><p>(<a href="#">{$vo.ask_posts}</a>)</p></td>
		</tr>
	</table>
	<table cellpadding="4" cellspacing="0" border="0" class="table-form tabs-item" rel="4">
		<tbody id="user_authoritys">
			<foreach name="authoritys" key='mkey' item="module" >
			<tr class="access-item">
				<th class="first tr" width="200">
					{$module.name}
				</th>
				<td>
					<p>
						<foreach name="module.actions" item="action">
						<label><input class="action-item" type="checkbox" name="access_node[{$mkey}][]" value="{$action}" <if condition="$ua_list[$mkey][$action]">checked="checked"</if>/><span>&nbsp;{:L('ACTION_'.$action)}</span></label>&nbsp;&nbsp;
						</foreach>&nbsp;
					</p>
				</td>
			</tr>
			</foreach>
		</tbody>
	</table>
</div>
<table cellpadding="4" cellspacing="0" border="0" class="table-form" style="border-top:none;">
	<tr class="act">
		<th width="200">&nbsp;</th>
		<td>
			<input type="hidden" name="uid" value="{$vo.uid}" />
			<input type="submit" class="submit_btn" value="{$Think.lang.SUBMIT}" />&nbsp;&nbsp;
			<input type="reset" class="reset_btn" value="{$Think.lang.RESET}" />
		</td>
	</tr>
</table>
</form>
<include file="Public:footer" />